import request from '@/utils/request'

export function getById(id) {
  return request({
    url: '/web-api/api/responsibilityGrid/findById?id' + id,
    method: 'get'
  })
}

export function getList() {
  return request({
    url: '/web-api/api/responsibilityGrid/list',
    method: 'get'
  })
}

export function getPage(query) {
  return request({
    url: '/web-api/api/responsibilityGrid',
    method: 'get',
    params: query
  })
}

export function add(data) {
  return request({
    url: '/web-api/api/responsibilityGrid',
    method: 'post',
    data
  })
}

export function del(ids) {
  return request({
    url: '/web-api/api/responsibilityGrid/',
    method: 'delete',
    data: ids
  })
}

export function edit(data) {
  return request({
    url: '/web-api/api/responsibilityGrid',
    method: 'put',
    data
  })
}

export const downloadUrl = '/web-api/api/responsibilityGrid/download'
